<template>
  <div class="home-container">
    <!-- 轮播图区域 -->
    <mt-swiper :lunbotu='lunbotu' img_name="img" :isfull='true'></mt-swiper>
    <!-- 九宫格 -->
    <ul class="mui-table-view mui-grid-view mui-grid-9">
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/newslist">
        <img src="../../static/images/menu1.png" alt />
          <div class="mui-media-body">新闻资讯</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/sharephote">
          <img src="../../static/images/menu2.png" alt />
          <div class="mui-media-body">图片分享</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/goodslist">
          <img src="../../static/images/menu3.png" alt />
          <div class="mui-media-body">商品购买</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/newslist">
          <img src="../../static/images/menu4.png" alt />
          <div class="mui-media-body">留言反馈</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/newslist">
         <img src="../../static/images/menu5.png" alt />
          <div class="mui-media-body">视频专区</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/newslist">
         <img src="../../static/images/menu6.png" alt />
          <div class="mui-media-body">联系我们</div>
        </router-link>
      </li>
    </ul>
  </div>
</template>

<script>
import MtSwiper from '../sub-components/Swiper.vue'
export default {
  components:{
    MtSwiper
  },

  created() {
    // 获取轮播图数据
    this.__getlunbotu();
  },
  data() {
    return {
      lunbotu: [] // 轮播图
    };
  },
  methods: {
    // ============= 发送网络请求========================
    async __getlunbotu() {
      const { data: res } = await this.$http.get("getlunbo");
      if (res.status !== 0) return;
      this.lunbotu = res.message;
    }
    // =============  事件监听 =========================
  }
};
</script>

<style scoped>


.mui-table-view.mui-grid-view.mui-grid-9 li img {
  width: 50%;
}

.mui-table-view.mui-grid-view.mui-grid-9 li .mui-media-body {
  font-size: 13px;
}

.mui-grid-view.mui-grid-9 {
  background-color: #fff;
}

.mui-grid-view.mui-grid-9 .mui-table-view-cell {
  border: none;
}
</style>>